package com.dzpk.gameserver.enumeration;

public enum OnlineActivityEnum {
    FIRST_CHARGE(10, 0), // 首充
    BUY_MALL(20, 0), // 商城购买道具
    PET_GROW_UP(30, 1) // 幻兽
    ;

    private int id;

    private int type; // 0:实时触发(比如购买道具) 1：不限制达成时间(如幻兽，可能比活动先到达满足)

    public int getId() {
        return id;
    }

    public int getType() {
        return type;
    }

    public static OnlineActivityEnum getById(int id) {
        for (OnlineActivityEnum en : OnlineActivityEnum.values()) {
            if (en.getId() == id) {
                return en;
            }
        }
        return null;
    }

    private OnlineActivityEnum(int id, int type) {
        this.id = id;
        this.type = type;
    }
}
